Skip to content

fix(driver-turso): make better-sqlite3 optional peer dependency for Vercel compatibility - #1132

Merged
xuyushun441-sys merged 1 commit into
mainfrom
claude/fix-driver-turso-requirement
Apr 14, 2026
Merged

xuyushun441-sys merged 1 commit into
mainfrom
claude/fix-driver-turso-requirement

Conversation

@Claude

@Claude Claude AI commented Apr 14, 2026

Copy link
Copy Markdown
Contributor

driver-turso was forcing better-sqlite3 installation for all users, causing Vercel deployments to fail due to native binding compilation errors. The driver only needs better-sqlite3 in local/replica modes, not remote mode.

Changes

  • Move better-sqlite3 to optional peer dependency — allows remote-only users to skip installation
  • Add better-sqlite3 to devDependencies — preserves test compatibility
  • Document dependency requirements by mode — clarifies when better-sqlite3 is needed

Usage

Remote mode (Vercel/Edge):

pnpm add @objectstack/driver-turso
# better-sqlite3 NOT required

Local/Replica modes:

pnpm add @objectstack/driver-turso better-sqlite3

The driver auto-detects mode from the URL — remote mode (libsql://) uses only @libsql/client, while local/replica modes (file:) extend SqlDriver and require better-sqlite3.

…ercel compatibility

Agent-Logs-Url: https://github.com/objectstack-ai/framework/sessions/d01337a6-ea24-478a-9cca-8b9ce8e46e39

Co-authored-by: xuyushun441-sys <255036401+xuyushun441-sys@users.noreply.github.com>
@vercel

vercel Bot commented Apr 14, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
objectstack-demo Error Error Apr 14, 2026 6:38am
objectstack-play Ready Ready Preview, Comment Apr 14, 2026 6:38am
spec Ready Ready Preview, Comment Apr 14, 2026 6:38am

Request Review

@xuyushun441-sys
xuyushun441-sys marked this pull request as ready for review April 14, 2026 06:38
@github-actions github-actions Bot added documentation Improvements or additions to documentation dependencies Pull requests that update a dependency file size/s labels Apr 14, 2026
@xuyushun441-sys
xuyushun441-sys merged commit 9f0712c into main Apr 14, 2026
11 of 12 checks passed
@github-actions
github-actions Bot deleted the claude/fix-driver-turso-requirement branch September 7, 2026 04:49

This branch had an error being deployed

1 failed and 2 active deployments
Preview – objectstack-play — 5d59665e Deployed Apr 14, 2026 by vercel[bot]
Preview – spec — 5d59665e Deployed Apr 14, 2026 by vercel[bot]
Preview – framework-example — 5d59665e Deployed Apr 14, 2026 by vercel[bot]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

dependencies Pull requests that update a dependency file documentation Improvements or additions to documentation size/s

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants